import {Component, OnInit} from '@angular/core';
import {ActivatedRoute, Router} from '@angular/router';
import {JlbService} from "../jlb.service";
import {SettingUrl} from "../../../public/setting/setting_url";

@Component({
  selector: 'app-jlb-ore-log-detail',
  templateUrl: './jlb-ore-log-detail.component.html',
  styleUrls: ['./jlb-ore-log-detail.component.css']
})
export class JlbOreLogDetailComponent implements OnInit {
  private id: string;
  public jlbOreLogInfo: any = {};//jlbOreLog信息

  constructor(private jlbService: JlbService, private route: ActivatedRoute, private router: Router) {
  }

  ngOnInit() {
    this.id = this.route.snapshot.params.code;//获取参数
    this.loadJlbOreLogInfo();//查询jlbOreLog类型列表
  }

  /**
   * 查询jlbOreLog信息
   */
  loadJlbOreLogInfo() {
    this.jlbService.loadJlbOreLogByCode(this.id).then((data: any) => {
      if (data) this.jlbOreLogInfo = data;
    })
  }

}
